<div class="dialog-container mdd-dialog mdl-shadow--8dp mdl-layout--fixed-header SMES-dialog B0204-dialog c-mdd-page" ng-init="dialog.init();" style="background-color: #fafafa" page-type="Dialog" _transclude-elem="[object Object]">
    <div class="kmi-header-row">
        <div class="header-title" ng-bind="dialog._title | translate"></div>
        <!--More Menu-->

        <!--Close button-->
        <div class="kmi-side-btn right" ng-click="dialog.hide();">
            <img src="image/icons/clear.png" />
            <div class="kmi-can-click"></div>
        </div>
    </div>
    <div class="kmi-layout-main-content" style="flex: 1">
        <!--Page-->
        <div class="kmi-layout-page">
            <div class="mdd-layout__with-toolbar mdd-layout c-mdd-layout" layout-name="B0204" page-name="" page-type="Dialog" with-toolbar="Y" reload="N" _transclude-elem="[object Object]" style="grid-template-columns: repeat(8, auto 1fr)">
                <label class="label" ng-show="dialog._event['workNo'].isShown != 'N'" style="" ng-bind="'B0204.columns.workNo' | translate"></label>
                <div class="value" ng-show="dialog._event['workNo'].isShown != 'N'" style="grid-column-start: span 7"><label class="value" ng-bind="dialog.wo_no" mdl-toast="{{dialog.wo_no}}" mdl-toast-passive="true"></label></div>
                <label class="label" ng-show="dialog._event['payMaterialsNo'].isShown != 'N'" style="" ng-bind="'B0204.columns.payMaterialsNo' | translate"></label>
                <div class="value" ng-show="dialog._event['payMaterialsNo'].isShown != 'N'" style="grid-column-start: span 7">
                    <input type="text" undefined="" id="payMaterialsNo" ng-model="dialog.tmPageCode.page_no" ng-keypress="dialog._event['payMaterialsNo'].change(dialog.tmPageCode.page_no, {event:$event});" ng-disabled="dialog._event['payMaterialsNo'].isDisabled == 'Y'" />
                    <div class="tip search">
                        <img src="image/icons/search.png" ng-click="dialog._event['payMaterialsNo'].click(dialog.tmPageCode.page_no, {event:$event});" ng-disabled="dialog._event['payMaterialsNo'].isDisabled == 'Y'" />
                    </div>
                </div>
                <div item-name="horizontal-line" style="border-bottom: solid 1px #cccccc; margin: 0 0 8px 0; grid-column-start: span 16;"></div>
                <label class="label" ng-show="dialog._event['materialPatchNo'].isShown != 'N'" style="" ng-bind="'B0204.columns.materialPatchNo' | translate"></label>
                <div class="value" ng-show="dialog._event['materialPatchNo'].isShown != 'N'" style="grid-column-start: span 7">
                    <input type="text" undefined="" id="materialPatchNo" ng-model="dialog.tmpLotNo" ng-keypress="dialog._event['materialPatchNo'].change(dialog.tmpLotNo, {event:$event});" ng-disabled="dialog._event['materialPatchNo'].isDisabled == 'Y'" />
                </div>
                <div item-name="qty" class="kmi-text-fields" style="grid-column-start: span 8">
                    <label class="label" ng-bind="'B0204.qty' | translate"></label>
                    <input id="B0204-qty" ng-model="dialog.tmpQty" mdl-calculater="dialog.tmpQty" mdl-calculater-decimal-length="3" style="margin-right: 8px" />
                    <button class="mdl-button mdl-js-button mdl-button--icon mdl-button--icon_prime" ng-click="dialog.addMaterials()">
                        <img src="image/icons/add.png" />
                    </button>
                </div>
                <div class="mdd-list c-mdd-list" null="" ng-show="dialog._event['B0204_list'].isShown != 'N'" style="height:{{dialog._event['B0204'].GetfillHeight()}};grid-column-start:span 16;" list-name="B0204_list" list-bind="dialog.B0204_list" list-alias="dialog.materialsInfo" enable-select="N" select-all="N" page-name="" page-type="Dialog" _transclude-elem="[object Object]">
                    <div class="kmi-list column-selector" kmi-scrollbar="520px" column-selector-id="B0204_list" style="flex: 1">
                        <div class="kmi-list__header">
                            <div class="kmi-list__column require width-fixed" style="flex:0 0 40px;">
                                <button class="mdl-button mdl-js-button mdl-button--icon" ng-click="dialog.selectAll(!dialog._isSelectAll);">
                                    <img ng-src="{{dialog._isSelectAll?'image/icons/check1.png':'image/icons/check0.png'}}">
                                </button>
                            </div>
                            <div class="kmi-list__column head-controls" style="flex: 1" ng-show="dialog._event['dialog.B0204_list.materials_no'].isShown != 'N'">
                                <div class="filter" ng-show="dialog._objB0204_list.header[0].isFilter">
                                    <input ng-model="dialog._objB0204_list.filterColumns['materials_no']" />
                                    <i class="material-icons clear" style="position: absolute; top: 2px; right: 4px" ng-click="dialog._objB0204_list.header[0].isFilter = false;dialog._objB0204_list.filterColumns['materials_no'] = '';">clear</i>
                                </div>

                                <div class="order" ng-hide="dialog._objB0204_list.header[0].isFilter">
                                    <i class="material-icons search" style="z-index: 1" ng-click="dialog._objB0204_list.header[0].isFilter = true">search</i>
                                    <label ng-bind="'B0204_list.columns.materials_no' | translate"></label>
                                    <i class="material-icons" ng-show="dialog._objB0204_list.queryOrder == 0">{{!dialog._objB0204_list.header[0].order?'':''}}</i>
                                    <div class="kmi-can-click" ng-click="dialog.orderResult(0, 'materials_no', 'dialog._objB0204_list');"></div>
                                </div>
                            </div>
                            <div class="kmi-list__column head-controls" style="flex: 1" ng-show="dialog._event['dialog.B0204_list.materials_lot_no'].isShown != 'N'">
                                <div class="filter" ng-show="dialog._objB0204_list.header[1].isFilter">
                                    <input ng-model="dialog._objB0204_list.filterColumns['materials_lot_no']" />
                                    <i class="material-icons clear" style="position: absolute; top: 2px; right: 4px" ng-click="dialog._objB0204_list.header[1].isFilter = false;dialog._objB0204_list.filterColumns['materials_lot_no'] = '';">clear</i>
                                </div>

                                <div class="order" ng-hide="dialog._objB0204_list.header[1].isFilter">
                                    <i class="material-icons search" style="z-index: 1" ng-click="dialog._objB0204_list.header[1].isFilter = true">search</i>
                                    <label ng-bind="'B0204_list.columns.materials_lot_no' | translate"></label>
                                    <i class="material-icons" ng-show="dialog._objB0204_list.queryOrder == 1">{{!dialog._objB0204_list.header[1].order?'':''}}</i>
                                    <div class="kmi-can-click" ng-click="dialog.orderResult(1, 'materials_lot_no', 'dialog._objB0204_list');"></div>
                                </div>
                            </div>
                            <div class="kmi-list__column head-controls" style="flex: 1" ng-show="dialog._event['dialog.B0204_list.inputLotNo'].isShown != 'N'">
                                <div class="filter" ng-show="dialog._objB0204_list.header[2].isFilter">
                                    <input ng-model="dialog._objB0204_list.filterColumns['inputLotNo']" />
                                    <i class="material-icons clear" style="position: absolute; top: 2px; right: 4px" ng-click="dialog._objB0204_list.header[2].isFilter = false;dialog._objB0204_list.filterColumns['inputLotNo'] = '';">clear</i>
                                </div>

                                <div class="order" ng-hide="dialog._objB0204_list.header[2].isFilter">
                                    <i class="material-icons search" style="z-index: 1" ng-click="dialog._objB0204_list.header[2].isFilter = true">search</i>
                                    <label ng-bind="'B0204_list.columns.inputLotNo' | translate"></label>
                                    <i class="material-icons" ng-show="dialog._objB0204_list.queryOrder == 2">{{!dialog._objB0204_list.header[2].order?'':''}}</i>
                                    <div class="kmi-can-click" ng-click="dialog.orderResult(2, 'inputLotNo', 'dialog._objB0204_list');"></div>
                                </div>
                            </div>
                            <div class="kmi-list__column head-controls" style="flex: 1" ng-show="dialog._event['dialog.B0204_list.qty'].isShown != 'N'">
                                <div class="filter" ng-show="dialog._objB0204_list.header[3].isFilter">
                                    <input ng-model="dialog._objB0204_list.filterColumns['qty']" />
                                    <i class="material-icons clear" style="position: absolute; top: 2px; right: 4px" ng-click="dialog._objB0204_list.header[3].isFilter = false;dialog._objB0204_list.filterColumns['qty'] = '';">clear</i>
                                </div>

                                <div class="order" ng-hide="dialog._objB0204_list.header[3].isFilter">
                                    <i class="material-icons search" style="z-index: 1" ng-click="dialog._objB0204_list.header[3].isFilter = true">search</i>
                                    <label ng-bind="'B0204_list.columns.qty' | translate"></label>
                                    <i class="material-icons" ng-show="dialog._objB0204_list.queryOrder == 3">{{!dialog._objB0204_list.header[3].order?'':''}}</i>
                                    <div class="kmi-can-click" ng-click="dialog.orderResult(3, 'qty', 'dialog._objB0204_list');"></div>
                                </div>
                            </div>
                        </div>
                        <div class="kmi-list__row-content">
                            <div class="kmi-list__row" id="B0204_list_result_list" ng-repeat="item in dialog._event['dialog.B0204_list'].getPages(dialog.materialsInfo, dialog._objB0204_list.PageConfig, dialog._objB0204_list.filterColumns, dialog._objB0204_list.header[dialog._objB0204_list.queryOrder]) track by $index" ng-class="{'is-select':dialog._event['dialog.B0204_list'].checkSelect(item, {index:$index, event:$event})}">
                                <div class="kmi-list__column" style="flex:0 0 40px;z-index:1;position: relative;">
                                    <button class="mdl-button mdl-js-button mdl-button--icon" ng-click="dialog.select($event, $index, item);">
                                        <img ng-src="{{item._isSelect?'image/icons/check1.png':'image/icons/check0.png'}}">
                                    </button>
                                </div>
                                <div class="kmi-list__column column-border" style="flex: 1" ng-bind="item.materials_no" ng-if="dialog._event['dialog.B0204_list.materials_no'].isShown != 'N'"></div>
                                <div class="kmi-list__column column-border" style="flex: 1" ng-bind="item.materials_lot_no" ng-if="dialog._event['dialog.B0204_list.materials_lot_no'].isShown != 'N'"></div>
                                <div class="kmi-list__column column-border" style="flex: 1" ng-bind="item.inputLotNo" ng-if="dialog._event['dialog.B0204_list.inputLotNo'].isShown != 'N'"></div>
                                <div class="kmi-list__column column-input" style="flex: 1; z-index: 1" ng-class="{'column-border':!$last}" ng-show="dialog._event['dialog.B0204_list.qty'].isShown != 'N'">
                                    <div class="kmi-text-fields">
                                        <input mdl-calculater="item.qty" mdl-calculater-decimal-length="3" ng-model="item.qty">
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="page-content">
                        <div class="page-icon">
                            <img src="image/icons/dropleft.png" />
                            <div class="kmi-can-click" ng-click="dialog.prevPage(dialog._objB0204_list.PageConfig);"></div>
                        </div>
                        <label ng-bind="dialog.pageInfo(dialog._objB0204_list.PageConfig);"></label>
                        <div class="page-icon">
                            <img src="image/icons/dropright.png" />
                            <div class="kmi-can-click" ng-click="dialog.nextPage(dialog._objB0204_list.PageConfig);"></div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="mdd-button-tool">
                <div class="tool-bar"></div>
                <div class="tool-bar" style="justify-content: flex-end">
                    <div class="kmi-button kmi-button-confrim btn-confirm" ng-disabled="dialog._fn['confirm'].isDisabled == 'Y'" ng-hide="dialog._fn['confirm'].isShown == 'N'" style="width: 100px">
                        <label ng-bind="'common.btn.confirm' | translate"></label>
                        <div class="kmi-can-click" ng-click="dialog._fn['confirm'].click('confirm');"></div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
